@treePrefixCls: rc-tree;
.@{treePrefixCls} {
  margin: 0;
  padding: 5px;
  li {
    padding: 0;
    margin: 0;
    list-style: none;
    white-space: nowrap;
    outline: 0;
    .draggable {
      color: #333;
      -moz-user-select: none;
      -khtml-user-select: none;
      -webkit-user-select: none;
      user-select: none;
      /* Required to make elements draggable in old WebKit */
      -khtml-user-drag: element;
      -webkit-user-drag: element;
    }
    &.drag-over {
      > .draggable {
        background-color: #316ac5;
        color: white;
        border: 1px #316ac5 solid;
        opacity: 0.8;
      }
    }
    &.drag-over-gap-top {
      > .draggable {
        border-top: 2px blue solid;
      }
    }
    &.drag-over-gap-bottom {
      > .draggable {
        border-bottom: 2px blue solid;
      }
    }
    &.filter-node {
      > .@{treePrefixCls}-node-content-wrapper {
        color: #a60000 !important;
        font-weight: bold !important;
      }
    }
    ul {
      margin: 0;
      padding: 0 0 0 18px;
    }
    .@{treePrefixCls}-node-content-wrapper {
      display: inline-block;
      padding: 1px 3px 0 0;
      margin: 0;
      cursor: pointer;
      height: 17px;
      text-decoration: none;
      vertical-align: top;
    }
    span {
      &.@{treePrefixCls}-switcher,
      &.@{treePrefixCls}-checkbox,
      &.@{treePrefixCls}-iconEle {
        line-height: 16px;
        margin-right: 2px;
        width: 16px;
        height: 16px;
        display: inline-block;
        vertical-align: middle;
        border: 0 none;
        cursor: pointer;
        outline: none;
        background-color: transparent;
        background-repeat: no-repeat;
        background-attachment: scroll;
        background-image: url('');

        &.@{treePrefixCls}-icon__customize {
          background-image: none;
        }
      }
      &.@{treePrefixCls}-icon_loading {
        margin-right: 2px;
        vertical-align: top;
        background: url('')
          no-repeat scroll 0 0 transparent;
      }
      &.@{treePrefixCls}-switcher {
        &.@{treePrefixCls}-switcher-noop {
          cursor: auto;
        }
        &.@{treePrefixCls}-switcher_open {
          background-position: -93px -56px;
        }
        &.@{treePrefixCls}-switcher_close {
          background-position: -75px -56px;
        }
      }
      &.@{treePrefixCls}-checkbox {
        width: 13px;
        height: 13px;
        margin: 0 3px;
        background-position: 0 0;
        &-checked {
          background-position: -14px 0;
        }
        &-indeterminate {
          background-position: -14px -28px;
        }
        &-disabled {
          background-position: 0 -56px;
        }
        &.@{treePrefixCls}-checkbox-checked.@{treePrefixCls}-checkbox-disabled {
          background-position: -14px -56px;
        }
        &.@{treePrefixCls}-checkbox-indeterminate.@{treePrefixCls}-checkbox-disabled {
          position: relative;
          background: #ccc;
          border-radius: 3px;
          &::after {
            content: ' ';
            -webkit-transform: scale(1);
            transform: scale(1);
            position: absolute;
            left: 3px;
            top: 5px;
            width: 5px;
            height: 0;
            border: 2px solid #fff;
            border-top: 0;
            border-left: 0;
          }
        }
      }
    }
  }
  &:not(.@{treePrefixCls}-show-line) {
    .@{treePrefixCls}-switcher-noop {
      background: none;
    }
  }
  &.@{treePrefixCls}-show-line {
    li:not(:last-child) {
      > ul {
        background: url('')
          0 0 repeat-y;
      }
      > .@{treePrefixCls}-switcher-noop {
        background-position: -56px -18px;
      }
    }
    li:last-child {
      > .@{treePrefixCls}-switcher-noop {
        background-position: -56px -36px;
      }
    }
  }
  &-child-tree {
    display: none;
    &-open {
      display: block;
    }
  }
  &-treenode-disabled {
    > span:not(.@{treePrefixCls}-switcher),
    > a,
    > a span {
      color: #767676;
      cursor: not-allowed;
    }
  }
  &-node-selected {
    background-color: #ffe6b0;
    border: 1px #ffb951 solid;
    opacity: 0.8;
  }
  &-icon__open {
    margin-right: 2px;
    background-position: -110px -16px;
    vertical-align: top;
  }
  &-icon__close {
    margin-right: 2px;
    background-position: -110px 0;
    vertical-align: top;
  }
  &-icon__docu {
    margin-right: 2px;
    background-position: -110px -32px;
    vertical-align: top;
  }
  &-icon__customize {
    margin-right: 2px;
    vertical-align: top;
  }
}
